package com.dapeng.cleardatabackend.model.dto.user;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * 用户注册请求体
 *
 * @author dapeng
 * @date 2024/12/05
 */
@Data
@ApiModel(description = "用户注册请求")
public class UserRegisterRequest implements Serializable {

    private static final long serialVersionUID = -378539961054497255L;

    /**
     * 用户账号
     */
    @ApiModelProperty(value = "用户账号", required = true)
    @NotNull(message = "用户账号不能为空")
    @Size(min = 4, max = 20, message = "用户账号长度需要在4-20位之间")
    private String userAccount;
    /**
     * 用户密码
     */
    @ApiModelProperty(value = "用户密码", required = true)
    @NotNull(message = "用户密码不能为空")
    @Size(min = 8, max = 20, message = "用户密码长度需要在8-20位之间")
    private String userPassword;

    /**
     * 校验密码
     */
    @ApiModelProperty(value = "校验密码")
    @Size(min = 8, max = 20, message = "校验密码长度需要在8-20位之间")
    private String checkPassword;
}
